package com.wzk.travelspringboot.dto;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @Author: WangZiKang
 * @Date: 2025/1/19 13:45
 */
@Data
public class ChangePasswordDTO {

    @NotNull(message = "用户id不能为空")
    private Long userId;

    //用户密码
    @NotBlank(message = "原始密码不能为空")
    @Length(min = 8,message = "原始密码长度不能少于8位！")
    private String oldPassword;

    //用户密码
    @NotBlank(message = "新密码不能为空")
    @Length(min = 8,message = "新密码长度不能少于8位！")
    private String newPassword;

    //用户密码
    @NotBlank(message = "确认密码不能为空")
    @Length(min = 8,message = "确认密码长度不能少于8位！")
    private String confirmPassword;

}
